<?php

/* 
 * The include path may change 
 * depending on PHPCodeProvider.php location. 
 */

include_once 'Classes/PHPCodeProvider.php';

/*
 * Create a PHPCodeProvider instance
 * so we can use PHPCodeProvider::isValidIdentifier() 
 */

$provider = new PHPCodeProvider();

/*
 * Test several if strings are valid PHP identifiers
 */

var_dump($provider->isValidIdentifier('validName'));
var_dump($provider->isValidIdentifier('15invalid'));
var_dump($provider->isValidIdentifier('**invalid'));
var_dump($provider->isValidIdentifier('not valid'));
var_dump($provider->isValidIdentifier('invalid*/'));

/*
 * The output should be:
 * 
 * boolean true
 * boolean false
 * boolean false
 * boolean false
 * boolean false
 * 
 */

?>
